package org.dlust.springbootmybatis.service.impl;

import org.dlust.springbootmybatis.mapper.UserMapper;
import org.dlust.springbootmybatis.pojo.User;
import org.dlust.springbootmybatis.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class UserServiceImpl implements UserService {
  private final UserMapper userMapper;

  public UserServiceImpl(UserMapper userMapper) {
    this.userMapper = userMapper;
  }

  @Override
  public User findById(Integer id) {

    return userMapper.findById(id);
  }
}
